package org.lemma.language;

import java.io.Serializable;
import java.util.ArrayList;
import javax.annotation.Author;
import javax.annotation.Copyright;
import javax.annotation.Version;

/**
 * <p>
 *  TODO: Javadoc for {@code Literal}
 * </p>
 *
 * @author Christopher Beatty [christopher.beatty@gmail.com]
 * @version 1.0.0
 */
@Version(
    major   = "1",
    minor   = "0",
    patch   = "0",
    date    = "2006-10-10T12:00:00-5:00",
    authors = { @Author(name = "Christopher Beatty", email = "christopher.beatty@gmail.com") }
)
@Copyright
public class Literal<L extends Language<L>> extends Expression<L> implements Serializable {

    /**
     * Determines if a de-serialized file is compatible with this class.
     *
     * Maintainers must change this value if and only if the new version
     * of this class is not compatible with old versions. See Sun docs
     * for <a href="http://java.sun.com/products/jdk/1.1/docs/guide
     * /serialization/spec/version.doc.html">details.</a>
     */
    private static final long serialVersionUID = 1L;

    private Literal() {
        super();
    }

    public Literal(String symbol) {
        super(symbol, new ArrayList<Formula<L>>());
    }

    @Override
    public Literal<L> clone() {
        return new Literal<L>(new String(this.operator()));
    }

}
